<script type="text/javascript">
	function freeProductPrev(number){
	
		var prev = <?php echo $curPage; ?> - number;
		var url = "<?php echo SystemProperties::$app_host;?>"+"/Product/getAjaxProductList/"+prev;
		//alert(url);
		doPost(url,'','productFreeDiv');
	}

	function freeProductNext(number){
		var next = <?php echo $curPage; ?> + number;
		var url = "<?php echo SystemProperties::$app_host;?>"+"/Product/getAjaxProductList/"+next;
		//alert(url);
		doPost(url,'','productFreeDiv');		
	}
	function freeProductFirst(){
		var url = "<?php echo SystemProperties::$app_host;?>"+"/Product/getAjaxProductList/1";
		//alert(url);
		doPost(url,'','productFreeDiv');		
	}
	function freeProductLast(){
		var url = "<?php echo SystemProperties::$app_host;?>"+"/Product/getAjaxProductList/10000";
		//alert(url);
		doPost(url,'','productFreeDiv');		
	}
 </script>
<table border="0" align="center" cellpadding="0" cellspacing="1" class="list">
  <tr>
    <td  align="center">选择</td>
    <td  align="center">ID</td>
	<td  align="center">名称</td>
	<td  align="center">品牌名称</td>
	<td  align="center">市值</td>
	<td  align="center">剩余数量</td>
	<td  align="center">人气</td>
    <td  align="center">图片</td>
    <td  align="center">描述</td>
    <td  align="center">管理</td>
  </tr>
  <?php if(isset($productList) && !empty($productList)){ ?>
<?php foreach($productList as $key=>$profiles){ ?>
  <tr>
    <td align="center"><label><?php echo $form->checkbox($profiles['g_products']['g_id']); ?></label></td>
    <td align="center"><?php echo $profiles['g_products']['g_id']?>　</td>
    <td align="center"><?php echo $profiles['g_products']['g_name']?>　</td>
	  <td align="center"><?php echo $profiles['g_products']['g_brand']?></td>
	    <td align="center"><?php echo $profiles['g_products']['g_jiazhi']?></td>
		  <td align="center"><?php echo $profiles['g_products']['g_number']?></td>
		    <td align="center"><?php echo $profiles['g_products']['popularity']?></td>
            <td align="center"><img src="<?php echo SystemProperties::$path.$profiles['g_products']['g_img']?>" width="80" height="80" /></td>
    <td align="center"><?php echo $toolTip->truncate($profiles['g_products']['g_description'],8);?></td>
    <td align="center"><a href="<?php echo SystemProperties::$app_host;?>/product/modifyPruduct/0/<?php echo $profiles['g_products']['g_id']?>" >修改</a>&nbsp;&nbsp;</td>
  </tr>
  <?php }?>
  <tr>
    <td colspan="12"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" class="page">
      <tr>
        <td width="30%"><input type="button" name="selectAll" value="全选" onClick="CheckAll(form2);"><input type="button" name="selectOther" value="反选" onClick="CheckOthers(form2);">&nbsp;<input type="submit" name="delAll" value="全部删除" onClick="return checkForm(form2);"></td>
       <td width="70%" align="center">
        <div class="div1"><ul class="d4"><li class="f"><a href="javascript:freeProductFirst();">首页</a></li><li title="上一页"><a href="javascript:freeProductPrev(1);">上一页</a></li><li title="上十页"><a href="javascript:freeProductPrev(10);"><<</a></li><li class="c"><?php echo $curPage;?>/<?php echo $totalPage;?></li><li title="下十页"><a href="javascript:freeProductNext(10);">>></a></li><li title="下一页"><a href="javascript:freeProductNext(1);">下一页</a></li><li class="l"><a href="javascript:freeProductLast();">尾页</a></li></ul></div><div class="div1"><ul class="s2"><li></li></ul></div>        </td>
      </tr>
    </table></td>
  </tr>
</table>
<?php } ?>